<!DOCTYPE html>
<html lang="en">
<head>

	<!-- start: Meta -->
	<meta charset="utf-8">
	<title>Bootstrap Metro Dashboard by Dennis Ji for ARM demo</title>
	<meta name="description" content="Bootstrap Metro Dashboard">
	<meta name="author" content="Dennis Ji">
	<meta name="keyword" content="Metro, Metro UI, Dashboard, Bootstrap, Admin, Template, Theme, Responsive, Fluid, Retina">
	<!-- end: Meta -->

	<!-- start: Mobile Specific -->
	<meta name="viewport" content="width=device-width, initial-scale=1">
	<!-- end: Mobile Specific -->

	<!-- start: CSS -->
	<link id="bootstrap-style" href="resources/admin/css/bootstrap.min.css" rel="stylesheet">
	<link href="resources/admin/css/bootstrap-responsive.min.css" rel="stylesheet">
	<link id="base-style" href="resources/admin/css/style.css" rel="stylesheet">
	<link id="base-style-responsive" href="resources/admin/css/style-responsive.css" rel="stylesheet">

	<!-- end: CSS -->


	<!-- The HTML5 shim, for IE6-8 support of HTML5 elements -->
	<!--[if lt IE 9]>
	  	<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
		<link id="ie-style" href="resources/admin/css/ie.css" rel="stylesheet">
	<![endif]-->

	<!--[if IE 9]>
		<link id="ie9style" href="resources/admin/css/ie9.css" rel="stylesheet">
	<![endif]-->

	<!-- start: Favicon -->
	<link rel="shortcut icon" href="img/favicon.ico">
	<!-- end: Favicon -->

			<style type="text/css">
			body { background: url(img/bg-login.jpg) !important; }
		</style>




</head>

<body>
		<div class="container-fluid-full">
		<div class="row-fluid">

			<div class="row-fluid">
				<div class="login-box">
					<div class="icons">
						<a href="index.html"><i class="halflings-icon home"></i></a>
						<a href="#"><i class="halflings-icon cog"></i></a>
					</div>
					<h2>Login to your account</h2>
					<form class="form-horizontal" action="" method="post">
						<fieldset>
							<div class="input-prepend" title="Username">
								<span class="add-on"><i class="halflings-icon user"></i></span>
								<input class="input-large span10" name="username" id="username" type="text" placeholder="帐号"
									<?php
										echo empty($_COOKIE['username']) ? 'value=""' : 'value="'.$_COOKIE['username'].'"';
									?>
								/>
							</div>
							<div class="clearfix"></div>

							<div class="input-prepend" title="Password">
								<span class="add-on"><i class="halflings-icon lock"></i></span>
								<input class="input-large span10" name="password" id="password" type="password" placeholder="密码"
									<?php
										echo empty($_COOKIE['password']) ? 'value=""' : 'value="'.$_COOKIE['password'].'"';
									?>
								/>
							</div>
							<div class="clearfix"></div>
							<div class="input-prepend" title="Password">
								<span class="add-on"><i class="halflings-icon lock"></i></span>
								<input class="input-large span6" name="code" id="code" type="text" placeholder="验证码"/>
								<img class="code" src="index.php?c=admin&a=code&admin=1" alt="">
							</div>
							<div class="clearfix"></div>

							<label class="remember" for="remember"><input type="checkbox" id="check" name="check" value="1"
									<?php
										if(!empty($_COOKIE['password']) && !empty($_COOKIE['username'])){
											echo 'checked="checked"';
										}
									?>
							/>记住我</label>
							<label class="remember" for="remember"><input type="checkbox" id="auto_login" name="auto_login" value="1" <?php
										if(!empty($_COOKIE['auto_login'])){
											echo 'checked="checked"';
										}
									?>
							/>自动登录</label>

							<div class="button-login">
								<button type="submit" class="btn btn-primary">登录</button>
							</div>
							<div class="clearfix"></div>
						</fieldset>
					</form>
					<hr>
					<h3><a href="index.php?c=index&a=index">前台</a></h3>
					<p>
						No problem, <a href="#">click here</a> to get a new password.
					</p>
				</div><!--/span-->
			</div><!--/row-->


	</div><!--/.fluid-container-->

		</div><!--/fluid-row-->
	    <div class="common-modal modal fade" id="common-Modal1" tabindex="-1" role="dialog" aria-hidden="true">
			<div class="modal-content">
				<ul class="list-inline item-details">
					<li><a href="#">Admin templates</a></li>
					<li><a href="http://themescloud.org">Bootstrap themes</a></li>
				</ul>
			</div>
		</div>
	<!-- start: JavaScript-->

		<script src="resources/admin/js/jquery-1.9.1.min.js"></script>
	<script src="resources/admin/js/jquery-migrate-1.0.0.min.js"></script>

		<script src="resources/admin/js/jquery-ui-1.10.0.custom.min.js"></script>

		<script src="resources/admin/js/jquery.ui.touch-punch.js"></script>

		<script src="resources/admin/js/modernizr.js"></script>

		<script src="resources/admin/js/bootstrap.min.js"></script>

		<script src="resources/admin/js/jquery.cookie.js"></script>

		<script src='js/fullcalendar.min.js'></script>

		<script src='js/jquery.dataTables.min.js'></script>

		<script src="resources/admin/js/excanvas.js"></script>
	<script src="resources/admin/js/jquery.flot.js"></script>
	<script src="resources/admin/js/jquery.flot.pie.js"></script>
	<script src="resources/admin/js/jquery.flot.stack.js"></script>
	<script src="resources/admin/js/jquery.flot.resize.min.js"></script>

		<script src="resources/admin/js/jquery.chosen.min.js"></script>

		<script src="resources/admin/js/jquery.uniform.min.js"></script>

		<script src="resources/admin/js/jquery.cleditor.min.js"></script>

		<script src="resources/admin/js/jquery.noty.js"></script>

		<script src="resources/admin/js/jquery.elfinder.min.js"></script>

		<script src="resources/admin/js/jquery.raty.min.js"></script>

		<script src="resources/admin/js/jquery.iphone.toggle.js"></script>

		<script src="resources/admin/js/jquery.uploadify-3.1.min.js"></script>

		<script src="resources/admin/js/jquery.gritter.min.js"></script>

		<script src="resources/admin/js/jquery.imagesloaded.js"></script>

		<script src="resources/admin/js/jquery.masonry.min.js"></script>

		<script src="resources/admin/js/jquery.knob.modified.js"></script>

		<script src="resources/admin/js/jquery.sparkline.min.js"></script>

		<script src="resources/admin/js/counter.js"></script>

		<script src="resources/admin/js/retina.js"></script>

		<script src="resources/admin/js/custom.js"></script>
	<!-- end: JavaScript-->

</body>
</html>

<script>

   $('#auto_login').click(function(){
   		//获取auto_login的选中属性
         if($(this).is(':checked')){
         	//把check的选中属性改成true
         	$('#check').prop('checked',true);
         	//把check的class父级添加选中属性
         	$('#check').parent().addClass('checked');
         }

   })
   $('#check').click(function(){
         if(!$(this).is(':checked')){
         	$('#auto_login').prop('checked',false);
         	$('#auto_login').parent().removeClass('checked');
         }

   })
	$('.code').click(function(){
			var src=$(this).attr('src');
			src=src+'&'+Math.round(Math.round())*10;
			$(this).attr('src',src);

	})
</script>
